Skip to content

Pin every workflow action to an exact current release - #4

Merged
benjipeng merged 1 commit into
mainfrom
chore/pin-workflow-actions
Aug 7, 2026
Merged

Pin every workflow action to an exact current release#4
benjipeng merged 1 commit into
mainfrom
chore/pin-workflow-actions

Conversation

@benjipeng

Copy link
Copy Markdown
Contributor

Both workflows were a major version behind on checkout, two majors behind on setup-uv, and carried floating tags elsewhere.

action was now
actions/checkout v6 v7.0.1
astral-sh/setup-uv v7 v9.0.0
actions/upload-artifact v7 v7.0.1
actions/download-artifact v8 v8.0.1
pypa/gh-action-pypi-publish release/v1 v1.14.2

Every version read from the upstream releases/latest, not from memory.

The setup-uv jump needed its changelog, not just its version number

Crossing two majors, so I read both release notes before touching it. Two things came out of that:

v8 stopped publishing major and minor tags deliberately. Pinning to @v9 would reopen exactly the supply-chain hole they closed after the tj-actions compromise — an exact release is the only supported form now. So this is not merely a style preference here; it is the upstream's requirement.

v9's single breaking change flips prune-cache from true to false, which grows the Actions cache instead of trimming it and can raise cost. That default is set back explicitly, so this upgrade changes versions and nothing else.

Their other breaking change — the manifest-file format — does not apply, since neither workflow defines one.

Also

Both checkouts set persist-credentials: false. Neither workflow pushes, so nothing needs the token left in .git/config.

Verification

⚠️ workflow.yaml only runs on a published release, so no pull request exercises it — the green check on this PR says nothing about the publish path. It was verified separately:

  • all three workflow files parsed locally
  • the release build job reproduced end to end:
    • uv build produced both artifacts, including the macosx_14_0_arm64 native wheel
    • check_release_artifacts.py passed on both
    • the native backend smoke test reported {'native': True, 'metal_available': True, ...}
  • the built wheel carries the new Homepage, Keywords, and description metadata

The Tests check on this PR does cover the risky half: it runs checkout@v7.0.1 and setup-uv@v9.0.0 on the same macos-15 runner and with the same inputs that workflow.yaml uses.

Both workflows were a major version behind on checkout and two majors
behind on setup-uv, and carried floating tags elsewhere.

- actions/checkout            v6          -> v7.0.1
- astral-sh/setup-uv          v7          -> v9.0.0
- actions/upload-artifact     v7          -> v7.0.1
- actions/download-artifact   v8          -> v8.0.1
- pypa/gh-action-pypi-publish release/v1  -> v1.14.2

The setup-uv jump crosses two majors, so its release notes decided two
details rather than the version number alone.

v8 stopped publishing major and minor tags on purpose: pinning to @v9
would reopen exactly the supply-chain hole they closed after tj-actions.
An exact release is the only supported form now.

v9's single breaking change flips `prune-cache` from true to false, which
grows the Actions cache instead of trimming it and can raise cost. That
default is set back explicitly, so the upgrade changes versions and
nothing else. Its other breaking change, the manifest-file format, does
not apply — neither workflow defines one.

Both checkouts now set persist-credentials: false. Neither workflow
pushes, so nothing needs the token left in .git/config.

workflow.yaml only runs on a published release, so no pull request
exercises it and the green check on this one says nothing about it. All
three workflow files were parsed locally, and the release build job was
reproduced end to end: uv build produced both artifacts including the
arm64 native wheel, check_release_artifacts.py passed, and the native
backend smoke test reported Metal available.
@benjipeng
benjipeng merged commit ed8bc2d into main Aug 7, 2026
1 check passed
@benjipeng
benjipeng deleted the chore/pin-workflow-actions branch August 7, 2026 22:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant